<?php $this->action("index","more","header");?>
 
        
<div id="content">
   <div class="main">
  		<h1>完成上传</h1>
		<div class="mod">
			<div class="bd">
				<div id="db-photo-view">
					<div class="photitle">
					    <span class='back-lnk'>&gt; <a href="http://site.douban.com/widget/photos/4063129/">返回相册</a></span>
					    <span class="nums">第<?php echo $photo_current_num;?>张 / 共<?php echo $photo_num;?>张</span>
					    <a href="<?php echo $this->getUrl("index","mod","detailphoto",array("siteid"=>$site_E->id,"modid"=>$mod_E->id,"photoid"=>$pre_photoid));?>" id="pre_photo">上一张</a>
					
					    /
					    <a href="<?php echo $this->getUrl("index","mod","detailphoto",array("siteid"=>$site_E->id,"modid"=>$mod_E->id,"photoid"=>$next_photoid));?>"   id="next_photo">下一张</a>
					</div>
				
				
						<div class="phoview">
						    <a class="mainphoto" href="<?php echo $this->getUrl("index","mod","detailphoto",array("siteid"=>$site_E->id,"modid"=>$mod_E->id,"photoid"=>$next_photoid));?>" title="点击查看下一张">
						        <img src="<?php echo $photo_E->getPhoto('600X600');?>" />
						    </a>
						
						</div>
					
						<div class="phodesc">
						    <div class="j a_editable edtext pl">
							        <span id="display"><?php echo $photo_E->descript;?></span>
							        <br/>
							        <span class="datetime">上传于<?php echo $photo_E->getCtime('Y-m-d');?></span>
							        <?php if($RootOper == 1){?>
							        <span id="edi">　<a href="<?php echo $this->getUrl("index","mod","modifyphoto",array("siteid"=>$site_E->id,"modid"=>$mod_E->id,"photoid"=>$photo_E->id));?>">修改</a></span>
							        <span>
									<a href="#" id="photo-del" rel="nofollow" title= "删除这张照片" class="j a_confirm_link">删除照片</a>
									</span>
							        <?php }?>
							        <span id="original"><a target="_blank" href="<?php echo $photo_E->photo;?>" title="查看原图">查看原图</a></span>
							    </div>
						</div>
					
					
					
					
					<script>
					Do('dialog', function () {
					  $(function () {
					  var    delUrl = '<?php echo $this->getUrl("index","mod","removephoto",array('siteid'=>$site_E->id,'modid'=>$mod_E->id,'photoid'=>$photo_E->id));?>';
					  var    mod_id = '<?php echo $mod_E->id;?>';
					  var    dlg = dui.Dialog(),
					  		 photoDelBn = $('#photo-del');
					  		
					  		
					  		  photoDelBn.click(function (e) {
					            e.preventDefault();
					            var site_id = $('body').attr('id'); //修改
					       	    var room_id = $('body').attr('rid'); //修改
					                dlg.set({
					                    width: 300,
					                    content: '确定要删除图片？',
					                    buttons: [{
					                        text: '确定',
					                        method: function (o) {
					                            o.close();
					                        	 $.post(
					                                delUrl, 
					                                function (me) {
					                                    // back to home
					                                    if(me.error)
					                                    {
					                                    	 dlg.set({
												                    width: 300,
												                    content: me.error,
												                    buttons: ['confirm']
												                }).open();
					                                    }
					                                    else
					                                    {
					                                   		location.href = '/allphoto/' + site_id + '/' + mod_id;
					                                   	}
					                                },
					                                'json'
					                            );
					                        }
					                    }, 'cancel']
					                }).open();
					                
					               });
					           
					        });
					  		
					  });
					
					
					</script>
					</div>
				</div>
		</div>
   </div>
	<div class="aside">
		<div class="mod" id="sp-user">
		    <div class="bd">
		
		    </div>
		</div>
     </div>
	        
</div>
<?php $this->partial("/Tpl/Index/MoreAction/doFooter.htm");?>  	
</body>
</html>